package com.innovation.sys.common.vo;

import java.io.Serializable;

public class ResultMap<T> implements Serializable {

	private static final long serialVersionUID = 1L;

	private String msg;

	private int code;

	private T data;

	private Long count;

	public ResultMap() {
		super();
	}

	public ResultMap(int code, String message) {
		super();
		this.code = code;
		this.msg = message;
	}

	public ResultMap(int code, String message, T data, Long count) {
		super();
		this.code = code;
		this.msg = message;
		this.data = data;
		this.count = count;
	}

	public String getMsg() {
		return msg;
	}

	public void setMsg(String msg) {
		this.msg = msg;
	}

	public Long getCount() {
		return count;
	}

	public void setCount(Long count) {
		this.count = count;
	}

	public int getCode() {
		return code;
	}

	public void setCode(int code) {
		this.code = code;
	}

	public T getData() {
		return data;
	}

	public void setData(T data) {
		this.data = data;
	}

	@Override
	public String toString() {
		return "{\"msg\":\"" + msg + "\",\"code\":\"" + code + "\",\"data\":\"" + data + "\",\"count\":\"" + count
				+ "\"}";
	}

}
